package sz.szsmk.citizencard.ui.activity;

import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import android.view.View;
import android.widget.EditText;
import android.widget.ImageView;
import android.widget.TextView;

import com.chenenyu.router.annotation.Route;

import sz.szsmk.citizencard.R;
import sz.szsmk.citizencard.ui.adapter.BusTransInputAdapter;
import sz.szsmk.citizencard.ui.base.IBaseActivity;

/**
 * Copyright (c)2018
 * author: zdh
 * created on: 2018/12/17 10:28
 * description:公交换乘输入
 */
@Route("BusTransInputActivity")
public class BusTransInputActivity extends IBaseActivity implements View.OnClickListener {
    ImageView back;
    TextView settingTitle;
    EditText searchEt;
    TextView searchCancel;
    RecyclerView busTransInputRv;
    private BusTransInputAdapter transInputAdapter;

    @Override
    protected int attachLayoutRes() {
        return R.layout.bus_trans_input_activity;
    }

    @Override
    protected void initInjector() {

    }

    @Override
    protected void initViews() {

        back = findViewById(R.id.back);
        settingTitle = findViewById(R.id.setting_title);
        searchEt = findViewById(R.id.search_et);
        searchCancel = findViewById(R.id.search_cancel);
        busTransInputRv = findViewById(R.id.bus_trans_input_rv);



        back.setOnClickListener(this);
        settingTitle.setText("换乘输入");

        LinearLayoutManager linearLayoutManager = new LinearLayoutManager(this);
        busTransInputRv.setLayoutManager(linearLayoutManager);
        transInputAdapter = new BusTransInputAdapter(this);
        busTransInputRv.setAdapter(transInputAdapter);

    }



    @Override
    protected void updateViews() {

    }

    @Override
    public void onClick(View v) {
        int id = v.getId();
        if (id == R.id.back) {
            finish();
        } else if (id == R.id.search_cancel) {
            finish();
        }
    }
}
